emacs.git
10 years agoDocument new features of TeX mode
Shakthi Kannan [Wed, 30 Dec 2015 17:46:55 +0000 (19:46 +0200)]
Document new features of TeX mode

* doc/emacs/text.texi (TeX Print): Document
'tex-print-file-extension'.
* doc/emacs/programs.texi (Misc for Programs): Document support
for Prettify Symbols mode in TeX mode.

10 years agoClarify docs of hscroll in RTL text
Eli Zaretskii [Wed, 30 Dec 2015 17:13:44 +0000 (19:13 +0200)]
Clarify docs of hscroll in RTL text

* doc/lispref/windows.texi (Horizontal Scrolling): Clarify the
meaning of a window's horizontal scroll amount for RTL paragraphs.

10 years agoFix rendering of HTML pages that use character composition
Eli Zaretskii [Wed, 30 Dec 2015 17:00:19 +0000 (19:00 +0200)]
Fix rendering of HTML pages that use character composition

* src/indent.c (Fvertical_motion): Fix the case when point starts
in the middle of a composition, as in shr-vertical-motion.
(Bug#22250)

10 years agoAvoid some compiler warnings in w32.c
Eli Zaretskii [Wed, 30 Dec 2015 16:26:56 +0000 (18:26 +0200)]
Avoid some compiler warnings in w32.c

* src/w32.c (codepage_for_filenames, crlf_to_lf)
(ansi_encode_filename, socket_to_fd, sys_write)
(check_windows_init_file): Avoid compiler warnings about
differences in pointer signedness.

10 years agoUndo ill-advised change
Dmitry Gutov [Wed, 30 Dec 2015 04:25:39 +0000 (06:25 +0200)]
Undo ill-advised change

* lisp/progmodes/xref.el (xref-collect-matches): Undo
ill-advised change.  The hits come in the order that `find'
produces them in, which isn't alphabetical.

10 years agoUnbreak completion in python-mode buffers
Dmitry Gutov [Wed, 30 Dec 2015 04:24:08 +0000 (06:24 +0200)]
Unbreak completion in python-mode buffers

* lisp/progmodes/python.el (python-shell-completion-at-point):
Unbreak in python-mode buffers.

10 years agoFix typos in CC Mode manual
Eli Zaretskii [Tue, 29 Dec 2015 20:56:53 +0000 (22:56 +0200)]
Fix typos in CC Mode manual

* doc/misc/cc-mode.texi (c-offsets-alist, Style Variables): Fix
typos.  (Bug#22267)

10 years agoAvoid assertion violations in compact_font_cache_entry
Eli Zaretskii [Tue, 29 Dec 2015 18:07:23 +0000 (20:07 +0200)]
Avoid assertion violations in compact_font_cache_entry

* src/alloc.c (compact_font_cache_entry): Don't use VECTORP to
avoid assertion violation in ASIZE.  (Bug#22263)

10 years agoFix filling text with bidirectional characters in shr.el
Eli Zaretskii [Tue, 29 Dec 2015 16:49:57 +0000 (18:49 +0200)]
Fix filling text with bidirectional characters in shr.el

* lisp/net/shr.el (shr-insert-document): Bind
bidi-display-reordering to nil while filling lines.  This is
required for when a line includes characters whose bidi
directionality is opposite to the base paragraph direction,
because columns are counted in the logical order.  (Bug#22250)

10 years ago* src/xfns.c (x_create_tip_frame): Process alpha parameter.
Martin Rudalics [Tue, 29 Dec 2015 16:41:15 +0000 (17:41 +0100)]
* src/xfns.c (x_create_tip_frame): Process alpha parameter.

10 years agoSync with Tramp 2.2.13
Michael Albinus [Tue, 29 Dec 2015 14:35:44 +0000 (15:35 +0100)]
Sync with Tramp 2.2.13

* doc/misc/trampver.texi: Change version to "2.2.13.25.1".

* lisp/net/tramp-compat.el (tramp-compat-delete-dups):
Use `tramp-compat-funcall'.

* lisp/net/tramp-gvfs.el (tramp-gvfs-parse-device-names):
Make `split-string' call compatible with older Emacsen.

* lisp/net/trampver.el: Change version to "2.2.13.25.1".

10 years ago* doc/misc/tramp.texi: Editorial revisions to the Tramp manual
Lambda Coder [Tue, 29 Dec 2015 14:33:54 +0000 (15:33 +0100)]
* doc/misc/tramp.texi: Editorial revisions to the Tramp manual

10 years agoMention that tls.el is secure by default, and will fail
Lars Ingebrigtsen [Tue, 29 Dec 2015 13:46:40 +0000 (14:46 +0100)]
Mention that tls.el is secure by default, and will fail

10 years agoMake tls.el use trustfiles by default
Lars Ingebrigtsen [Tue, 29 Dec 2015 13:46:20 +0000 (14:46 +0100)]
Make tls.el use trustfiles by default

* lisp/net/tls.el (tls-program): Add a certfile by default (bug#21227).
(open-tls-stream): Insert the trustfile by looking at
`gnutls-trustfiles'.

10 years agoRefactor out gnutls-trustfiles
Lars Ingebrigtsen [Tue, 29 Dec 2015 13:39:53 +0000 (14:39 +0100)]
Refactor out gnutls-trustfiles

* lisp/net/gnutls.el (gnutls-trustfiles): Refactor out for reuse by tls.el.

10 years agoRemove --insecure from gnutls-cli invocation
Lars Ingebrigtsen [Tue, 29 Dec 2015 13:30:53 +0000 (14:30 +0100)]
Remove --insecure from gnutls-cli invocation

* tls.el (tls-program): Default to using secure TLS
connections (bug#19284).

10 years agoSpelling fix
Paul Eggert [Tue, 29 Dec 2015 03:05:50 +0000 (19:05 -0800)]
Spelling fix

10 years agoPort report-emacs-bug to deterministic builds
Paul Eggert [Tue, 29 Dec 2015 02:43:09 +0000 (18:43 -0800)]
Port report-emacs-bug to deterministic builds

* lisp/mail/emacsbug.el (report-emacs-bug): Future-proof the
recent "built on" change to deterministic builds where
emacs-build-system will be nil.  See:
http://lists.gnu.org/archive/html/emacs-devel/2015-12/msg01369.html

10 years ago; * lisp/progmodes/project.el: Update TODO
Dmitry Gutov [Tue, 29 Dec 2015 01:53:32 +0000 (03:53 +0200)]
; * lisp/progmodes/project.el: Update TODO

10 years agoFix URL auth error message
Jose A. Ortega Ruiz [Tue, 29 Dec 2015 00:27:48 +0000 (01:27 +0100)]
Fix URL auth error message

* lisp/url/url-http.el (url-http-handle-authentication): Make the error
message more correct (bug#20069).

Copyright-paperwork-exempt: yes

10 years agoshr link traversal fixup
Lars Ingebrigtsen [Mon, 28 Dec 2015 20:55:18 +0000 (21:55 +0100)]
shr link traversal fixup

* shr.el (shr-next-link): Don't bug out on adjacent links.

Backport:

(cherry picked from commit 1efc5f8b09273c359683ce13be95fb5df7a84311)

10 years agoset :safe on css-indent-offset
Tom Tromey [Mon, 28 Dec 2015 20:00:56 +0000 (13:00 -0700)]
set :safe on css-indent-offset

* lisp/textmodes/css-mode.el (css-indent-offset): Add :safe 'integerp.

10 years ago* eww.el (eww-mode): Remove superfluous bidi reset.
Lars Ingebrigtsen [Mon, 28 Dec 2015 20:02:43 +0000 (21:02 +0100)]
* eww.el (eww-mode): Remove superfluous bidi reset.

10 years agoMake chunked encoding trailer detection more compliant
James Stout [Mon, 28 Dec 2015 19:49:57 +0000 (20:49 +0100)]
Make chunked encoding trailer detection more compliant

* lisp/url/url-http.el
(url-http-chunked-encoding-after-change-function): Make
trailer detection more compliant (bug#16345).

Copyright-paperwork-exempt: yes

10 years agoFix Bug#10873 in `report-emacs-bug'
Martin Rudalics [Mon, 28 Dec 2015 18:11:22 +0000 (19:11 +0100)]
Fix Bug#10873 in `report-emacs-bug'

* lisp/mail/emacsbug.el (report-emacs-bug): If
`report-emacs-bug-no-explanations' is nil, make sure we can show
mail and warnings buffer on this frame (Bug#10873).

10 years agoAlways reset the bidi direction
Lars Ingebrigtsen [Mon, 28 Dec 2015 17:11:56 +0000 (18:11 +0100)]
Always reset the bidi direction

* eww.el (eww-display-html): Always reset the bidi direction
to `left-to-right' (bug#22257).

10 years agoAllow line comments ending with escaped NL to be continued to the next line.
Alan Mackenzie [Mon, 28 Dec 2015 16:01:05 +0000 (16:01 +0000)]
Allow line comments ending with escaped NL to be continued to the next line.

Use this in C, C++, and Objective C Modes.  Fixes bug#22246

* src/syntax.c (comment-end-can-be-escaped): New buffer local variable.
(forw-comment, back-comment): On encountering an end of comment character,
test whether it is escaped when `comment-end-can-be-escaped' is non-nil.

* doc/lispref/syntax.texi (Control Parsing): Describe
`comment-end-can-be-escaped'.

* etc/NEWS (Lisp Changes): Describe `comment-end-can-be-escaped'.

* lisp/progmodes/cc-langs.el: New c-lang-setvar `comment-end-can-be-escaped'.

10 years agoRename project-library-roots to project-external-roots
Dmitry Gutov [Mon, 28 Dec 2015 04:17:19 +0000 (06:17 +0200)]
Rename project-library-roots to project-external-roots

* lisp/progmodes/project.el (project-library-roots): Rename to
project-external-roots.
(project-library-roots-function): Rename to
project-vc-external-roots-function.  Only use it in the VC
backend, for now.  Update project-external-roots accordingly.
(project-vc-library-roots): Remove.
(project-or-libraries-find-regexp):
Rename to project-or-external-find-regexp.

* lisp/progmodes/elisp-mode.el (elisp-library-roots):
Rename to elisp-load-path-roots.

* lisp/progmodes/etags.el (etags-library-roots): Remove.  Use
an anonymous function for the default value of
project-vc-external-roots-function.

10 years agoClear erc user list upon disconnection
Deniz Dogan [Sun, 27 Dec 2015 21:36:55 +0000 (22:36 +0100)]
Clear erc user list upon disconnection

* lisp/erc/erc-backend.el (erc-process-sentinel): Clear channel user
lists upon disconnection.  This prevents invalid channel
user lists when reconnecting (bug#10947).

10 years agoDon't bug out in erc after waking from sleep
Lars Ingebrigtsen [Sun, 27 Dec 2015 21:18:32 +0000 (22:18 +0100)]
Don't bug out in erc after waking from sleep

* erc-backend.el (erc-server-send-ping): If the server has
closed connection, this may already have been detected and
`erc-server-last-received-time' has been set to nil (bug#13608).

10 years agoProxy error in erc with multiple clients
David Edmondson [Sun, 27 Dec 2015 20:33:01 +0000 (21:33 +0100)]
Proxy error in erc with multiple clients

* lisp/erc/erc.el (erc-channel-receive-names): Fix errors
generated when multiple IRC clients talk to a single IRC proxy
(bug#19034).

Backport:

(cherry picked from commit 507e98a54d1aa37823c64993d6b59257a82fe8f4)

10 years agoEnsure that we don't have several timers in erc
Dima Kogan [Sun, 27 Dec 2015 20:19:13 +0000 (21:19 +0100)]
Ensure that we don't have several timers in erc

* lisp/erc/erc-backend.el (erc-server-setup-periodical-ping): Checks
for existing timers in the alist before adding new ones.  If a
timer already exists, it is cancelled and
overwritten. (bug#19292).

10 years agoFix mml-sec build warnings
Jens Lechtenboerger [Sun, 27 Dec 2015 20:12:16 +0000 (21:12 +0100)]
Fix mml-sec build warnings

* lisp/gnus/mml-sec.el: Fix warnings by adding autoloads
(bug#18718).

Backport:

(cherry picked from commit 3603097f62f5f4aa5451716e9ac380161f6829e2)

10 years agoDon't insert erc logs at the end
Lars Ingebrigtsen [Sun, 27 Dec 2015 20:08:01 +0000 (21:08 +0100)]
Don't insert erc logs at the end

* erc-log.el (erc-log-setup-logging): Insert the previous log
at the start of the buffer, not at the end (bug#20496).

10 years ago(eww-setup-buffer): Restore left-to-right defaults
Lars Ingebrigtsen [Sun, 27 Dec 2015 19:35:05 +0000 (20:35 +0100)]
(eww-setup-buffer): Restore left-to-right defaults

* eww.el (eww-setup-buffer): Restore left-to-right defaults.

Backport:

(cherry picked from commit 96c874b96b617c124d500a94de761a61f2a08685)

10 years agoDon't join erc channels doubly
Lars Ingebrigtsen [Sun, 27 Dec 2015 19:25:57 +0000 (20:25 +0100)]
Don't join erc channels doubly

* erc-join.el (erc-autojoin-channels): Don't join channels
more than once (if you have several nicks) (bug#20695).

10 years agoAvoid leaving "ghost" of mouse pointer on MS-Windows
Eli Zaretskii [Sun, 27 Dec 2015 18:52:21 +0000 (20:52 +0200)]
Avoid leaving "ghost" of mouse pointer on MS-Windows

* src/w32term.c (frame_set_mouse_pixel_position):
* src/w32fns.c (Fw32_mouse_absolute_pixel_position): Momentarily
disable "mouse trails" when moving the mouse pointer.  (Bug#22247)
* src/w32term.c (frame_set_mouse_pixel_position): Include
w32common.h.

10 years agoFix auth source lookups from erc with port numbers
Krzysztof Jurewicz [Sun, 27 Dec 2015 08:04:02 +0000 (09:04 +0100)]
Fix auth source lookups from erc with port numbers

* lisp/erc/erc.el (erc-open): `auth-source' wants strings, not port
numbers (bug#20541).

Copyright-paperwork-exempt: yes

10 years agoRun erc-kill-channel-hook always on exit
Fran Litterio [Sun, 27 Dec 2015 07:56:45 +0000 (08:56 +0100)]
Run erc-kill-channel-hook always on exit

* lisp/erc/erc.el (erc-kill-buffer-function): Run erc-kill-channel-hook
when erc-kill-queries-on-quit is set (bug#21187).

10 years agoSpelling fix
Paul Eggert [Sat, 26 Dec 2015 23:39:40 +0000 (15:39 -0800)]
Spelling fix

* test/automated/url-parse-tests.el:
(url-generic-parse-url/same-document-reference):
Rename from url-generic-parse-url/same-decument-reference.

10 years agoReword initial *scratch* for brevity, appearance
Paul Eggert [Sat, 26 Dec 2015 23:22:28 +0000 (15:22 -0800)]
Reword initial *scratch* for brevity, appearance

* lisp/startup.el (initial-scratch-message):
Reword to avoid apostrophes, and to make it shorter.
See the thread starting in:
http://lists.gnu.org/archive/html/emacs-devel/2015-12/msg01241.html

10 years agoAdd ert-deftest to lisp-mode.el
Leo Liu [Sat, 26 Dec 2015 20:44:11 +0000 (04:44 +0800)]
Add ert-deftest to lisp-mode.el

* lisp-mode.el (lisp-imenu-generic-expression,
  lisp-el-font-lock-keywords-1): Add ert-deftest.

10 years agoMark imap changes as not needing doc changes
Lars Ingebrigtsen [Sat, 26 Dec 2015 20:48:10 +0000 (21:48 +0100)]
Mark imap changes as not needing doc changes

10 years ago* imap.el (imap-ssl-open): Remove
Lars Ingebrigtsen [Sat, 26 Dec 2015 20:47:20 +0000 (21:47 +0100)]
* imap.el (imap-ssl-open): Remove

10 years agoUse built-in encryption in imap.el
Lars Ingebrigtsen [Sat, 26 Dec 2015 20:45:51 +0000 (21:45 +0100)]
Use built-in encryption in imap.el

* lisp/net/imap.el (imap-ssl-program): Remove (bug#21134).
(imap-starttls-open): Use open-network-stream instead of starttls.el.
(imap-tls-open): Use open-network-stream instead of tls.el.

10 years agoDon't try using /bin/sh in artist.el on MS-Windows
Eli Zaretskii [Sat, 26 Dec 2015 20:35:48 +0000 (22:35 +0200)]
Don't try using /bin/sh in artist.el on MS-Windows

* lisp/textmodes/artist.el (artist-figlet-get-font-list-windows):
New function.
(artist-figlet-choose-font): Use it on MS-Windows and MS-DOS.
(Bug#20167)

10 years agoAlways define gmalloc etc. in src/gmalloc.c
Wolfgang Jenkner [Sat, 26 Dec 2015 20:12:02 +0000 (12:12 -0800)]
Always define gmalloc etc. in src/gmalloc.c

This is a work-around to prevent the compiler from using semantic
knowledge about malloc for optimization purposes.  E.g., gcc 5.2
with -O2 replaces most of calloc's definition by a call to calloc;
see Bug#22085.
* src/gmalloc.c [!HYBRID_MALLOC] (malloc, realloc, calloc)
(aligned_alloc, free): Do not undef.  Instead, define these as
functions (perhaps renamed to gmalloc etc.) in terms of gmalloc etc.

10 years agoFix documentation of browse-url browser-related functions
Eli Zaretskii [Sat, 26 Dec 2015 18:47:42 +0000 (20:47 +0200)]
Fix documentation of browse-url browser-related functions

* lisp/net/browse-url.el (browse-url)
(browse-url-default-browser, browse-url-default-windows-browser)
(browse-url-default-macosx-browser, browse-url-chromium)
(browse-url-kde, browse-url-text-xterm): Clarify the usage of ARGS
and NEW-WINDOW arguments in these functions.  (Bug#19421)

10 years agoPropagate Bug#14412 fix to backtrace_eval_unrewind
Paul Eggert [Sat, 26 Dec 2015 17:30:22 +0000 (09:30 -0800)]
Propagate Bug#14412 fix to backtrace_eval_unrewind

* src/eval.c (unbind_to): Redo so that the FALLTHROUGH!! comment
becomes accurate again. This shouldn’t affect behavior.
(backtrace_eval_unrewind): Apply the recent unbind_to fix here, too.

10 years ago; * etc/NEWS: Update entries for VHDL and Calculator.
Eli Zaretskii [Sat, 26 Dec 2015 17:08:15 +0000 (19:08 +0200)]
; * etc/NEWS: Update entries for VHDL and Calculator.

10 years agoDon't produce non-ASCII characters in *scratch*
Eli Zaretskii [Sat, 26 Dec 2015 16:58:04 +0000 (18:58 +0200)]
Don't produce non-ASCII characters in *scratch*

* lisp/startup.el (initial-scratch-message): Quote apostrophes to
avoid producing non-ASCII characters in the *scratch* buffer's
commentary.

10 years agoDocument changes in 'compare-windows'
Eli Zaretskii [Sat, 26 Dec 2015 16:30:07 +0000 (18:30 +0200)]
Document changes in 'compare-windows'

* lisp/vc/compare-w.el (compare-windows-removed)
(compare-windows-added): Doc fix.

* doc/emacs/files.texi (Comparing Files): Document the changes in
window selection by 'compare-windows'.

10 years agoDocument 'vc-annotate-background-mode'
Eli Zaretskii [Sat, 26 Dec 2015 16:04:03 +0000 (18:04 +0200)]
Document 'vc-annotate-background-mode'

* doc/emacs/maintaining.texi (Old Revisions): Document
'vc-annotate-background-mode'.

10 years agoDocument 'vc-region-history'
Eli Zaretskii [Sat, 26 Dec 2015 15:52:53 +0000 (17:52 +0200)]
Document 'vc-region-history'

* doc/emacs/maintaining.texi (VC Change Log): Document
'vc-region-history'.

10 years agoImprove documentation of 'vc-push'
Eli Zaretskii [Sat, 26 Dec 2015 15:09:25 +0000 (17:09 +0200)]
Improve documentation of 'vc-push'

* doc/emacs/maintaining.texi (Pulling / Pushing): Expand and
improve the documentation of 'vc-push'.

* lisp/vc/vc.el (vc-pull, vc-push): Doc fix.

10 years ago; * etc/NEWS: Document new features of SQL Mode.
Eli Zaretskii [Sat, 26 Dec 2015 14:30:22 +0000 (16:30 +0200)]
; * etc/NEWS: Document new features of SQL Mode.

10 years agoInclude the tests for the URL parsing fixes
Alain Schneble [Sat, 26 Dec 2015 13:52:43 +0000 (14:52 +0100)]
Include the tests for the URL parsing fixes

10 years agoMake relative URL parsing and resolution consistent with RFC 3986 (bug#22044)
Alain Schneble [Fri, 25 Dec 2015 23:50:25 +0000 (00:50 +0100)]
Make relative URL parsing and resolution consistent with RFC 3986 (bug#22044)

* test/lisp/url/url-parse-tests.el: Add tests covering url-generic-parse-url.
* test/lisp/url/url-expand-tests.el: Add tests covering url-expand-file-name.
* lisp/url/url-parse.el (url-generic-parse-url): Keep empty fragment
information in URL-struct.
* lisp/url/url-parse.el (url-path-and-query): Do not artificially turn empty
path and query into nil path and query, respectively.
* lisp/url/url-expand.el (url-expander-remove-relative-links): Do not turn
empty path into an absolute ("/") path.
* lisp/url/url-expand.el (url-expand-file-name): Properly resolve
fragment-only URIs. Do not just return them unchanged.
* lisp/url/url-expand.el (url-default-expander): An empty path in the relative
reference URI should not drop the last segment.

Backport:

(cherry picked from commit b792ecea1715e080ad8e232d3d154b8a25d2edfb)

10 years ago; * etc/NEWS: Mark some URL entries as not requiring documentation changes
Eli Zaretskii [Sat, 26 Dec 2015 13:49:42 +0000 (15:49 +0200)]
; * etc/NEWS: Mark some URL entries as not requiring documentation changes

10 years agoDocument 'url-user-agent'.
Eli Zaretskii [Sat, 26 Dec 2015 13:31:32 +0000 (15:31 +0200)]
Document 'url-user-agent'.

* lisp/url/url-http.el (url-user-agent): Move from here...
* lisp/url/url-vars.el (url-user-agent): ...to here.  This is to
keep all the URL defcustoms in one place, and also have it defined
whenever the URL library is loaded.

* doc/misc/url.texi (Customization): Document 'url-user-agent'.

10 years agoDocument protocols supported by URL library via Tramp
Eli Zaretskii [Sat, 26 Dec 2015 12:59:50 +0000 (14:59 +0200)]
Document protocols supported by URL library via Tramp

* doc/misc/url.texi (Tramp): New node, describes the URL schemes
supported via Tramp.
(Supported URL Types, file/ftp, rlogin/telnet/tn3270): Mention
Tramp.

10 years agoDocument changes in Shell-script mode
Eli Zaretskii [Sat, 26 Dec 2015 11:48:00 +0000 (13:48 +0200)]
Document changes in Shell-script mode

* lisp/progmodes/sh-script.el (sh-mode, sh-set-shell): Document
the 'sh-shell' file-local variable.
(top level): Add an auto-load form to avoid byte-compiler warning
about 'comint-send-string'.

10 years agoFix documentation of 'ses-define-local-printer'
Eli Zaretskii [Sat, 26 Dec 2015 11:16:15 +0000 (13:16 +0200)]
Fix documentation of 'ses-define-local-printer'

* doc/misc/ses.texi (Printer functions): Fix whitespace between
sentences and punctuation.  Add an index entry for
'ses-define-local-printer'.

10 years agoDocument 'ert-summarize-tests-batch-and-exit'
Shakthi Kannan [Sat, 26 Dec 2015 11:05:06 +0000 (13:05 +0200)]
Document 'ert-summarize-tests-batch-and-exit'

* doc/misc/ert.texi (Running Tests in Batch Mode): Document
'ert-summarize-tests-batch-and-exit'.

10 years agoAvoid assertion violation in unbind_to
Eli Zaretskii [Sat, 26 Dec 2015 10:43:08 +0000 (12:43 +0200)]
Avoid assertion violation in unbind_to

* src/eval.c (unbind_to) <SPECPDL_LET>: Avoid assertion violation
if we get here with an object that is not a symbol.  (Bug#14412)

10 years agoDon't treat /foo/bar:mumble as ange-ftp address
Andreas Schwab [Fri, 25 Dec 2015 22:32:55 +0000 (23:32 +0100)]
Don't treat /foo/bar:mumble as ange-ftp address

* lisp/net/browse-url.el (browse-url-filename-alist): Match colons
only in the first component.  (bug#5362)

10 years agoFollow <meta> redirects in eww
Lars Ingebrigtsen [Fri, 25 Dec 2015 17:18:42 +0000 (18:18 +0100)]
Follow <meta> redirects in eww

Merge conflict, but I think I resolved it.

    Follow meta refresh tags in eww

    * eww.el (eww-tag-meta): Follow meta refresh tags (bug#22234).

Backport:

10 years agoAllow http://user:pass@foo/ URLs again
Lars Ingebrigtsen [Fri, 25 Dec 2015 19:21:46 +0000 (20:21 +0100)]
Allow http://user:pass@foo/ URLs again

* lisp/url/url-auth.el (url-basic-auth): Allow explicit
user/passwords in URLs (bug#19046).

Backport:

(cherry picked from commit b563715a2db265517d5a77f165a42afa1e233fdd)

10 years agoAutoload url-insert-buffer-contents
Samer Masterson [Fri, 25 Dec 2015 18:04:55 +0000 (19:04 +0100)]
Autoload url-insert-buffer-contents

* lisp/url/url-handlers.el: Add autoload cookie so that
`package-list-packages' doesn't bug out (bug#21927) (tiny change)

Backport:

(cherry picked from commit 7a7b5b492ff9929eecd90c4564db6fbf3b192323)

10 years agoMake sure *scratch* etc. use forward slashes in its default-directory
Eli Zaretskii [Fri, 25 Dec 2015 16:37:31 +0000 (18:37 +0200)]
Make sure *scratch* etc. use forward slashes in its default-directory

* lisp/startup.el (normal-top-level): On MS-Windows, convert
backslashes to forward slashes while decoding default-directory
of the initially-created buffers.

10 years agoMore eww file name coding fixes
Lars Ingebrigtsen [Fri, 25 Dec 2015 07:31:10 +0000 (08:31 +0100)]
More eww file name coding fixes

* eww.el (eww-decode-url-file-name): Use the base coding
system to check for encodability.

Backport:

(cherry picked from commit a8627008abe4ab339df19b417776da28b3ce0fc7)

10 years agoAlways save eww history
Lars Ingebrigtsen [Fri, 25 Dec 2015 06:56:08 +0000 (07:56 +0100)]
Always save eww history

* eww.el (eww-setup-buffer): Always save history, even when
called from outside the eww buffer (bug#19638).

Backport:

(cherry picked from commit 2a0f18d9b6ce0ccce3d9c4a4a3b5743bae71b41e)

10 years agoDefault web pages to right-to-left
Lars Ingebrigtsen [Fri, 25 Dec 2015 06:45:27 +0000 (07:45 +0100)]
Default web pages to right-to-left

* eww.el (eww-mode): Most web pages are left-to-right, so make
that the default (bug#19801).

* shr.el (shr-tag-html): Respect "dir" attributes
(left-to-right, right-to-left).

Backport:

(cherry picked from commit 9e089ec8a380ec3758fcf1564c5f86dc92c68c2a)

10 years agoMake toggling checkboxes work again
Lars Ingebrigtsen [Fri, 25 Dec 2015 05:47:28 +0000 (06:47 +0100)]
Make toggling checkboxes work again

* eww.el (eww-update-field): Make toggling checkboxes work
again (bug#21881).

Backport:

(cherry picked from commit 5e56f606952e5e81b4d3a93ea70e791b74b33041)

10 years agoDon't store cookies with empty names
Lars Ingebrigtsen [Fri, 25 Dec 2015 05:33:25 +0000 (06:33 +0100)]
Don't store cookies with empty names

* lisp/url/url-cookie.el (url-cookie-store): Refuse to store
cookies with empty names (bug#21936).

Backport:

(cherry picked from commit 9f0fd7cb1aec3eb9e2e0f7b8854c30870286d96c)

10 years agoStop rendering HTML before specdlr exhaustion
Lars Ingebrigtsen [Fri, 25 Dec 2015 05:19:34 +0000 (06:19 +0100)]
Stop rendering HTML before specdlr exhaustion

Fixes: 22117
* shr.el (shr-descend): Stop rendering before we run out of
specpdl room (bug#22117).

Backport:

(cherry picked from commit 248da292fe46224b0b5a79b632c89cf4de2c2081)

10 years agoUse cl-reduce, not reduce.
Lars Ingebrigtsen [Fri, 25 Dec 2015 05:04:01 +0000 (06:04 +0100)]
Use cl-reduce, not reduce.

Backport:

(cherry picked from commit fe4606f93b91ff3d046aee0cf21ecc277af7a786)

10 years agoAllow several <tbody> tags in shr
Lars Ingebrigtsen [Fri, 25 Dec 2015 05:01:19 +0000 (06:01 +0100)]
Allow several <tbody> tags in shr

* shr.el (shr-table-body): New function to find the real body
of a table.
(shr-tag-table): Use it to render several <tbody> tags in a
table (bug#22170).

Backport:

(cherry picked from commit cdaf33029d6620073833876d76056045ecfbc7c4)

10 years agoMake prettier unique file names in eww
Lars Ingebrigtsen [Thu, 24 Dec 2015 21:47:58 +0000 (22:47 +0100)]
Make prettier unique file names in eww

(eww-make-unique-file-name): Make unique file names by making
files like foo(2).jpg instead of foo(1)(2).jpg.

Backport:

(cherry picked from commit edfdd0a6cbdfa9e5e4bd0553e2b489401ca39266)

10 years agoDecode hex-encoded URLs before using them as file names
Lars Ingebrigtsen [Thu, 24 Dec 2015 21:21:24 +0000 (22:21 +0100)]
Decode hex-encoded URLs before using them as file names

* eww.el (eww-decode-url-file-name): New function.
(eww-download-callback): Use it to decode file names before
saving them.

Backport:

(cherry picked from commit af22a010d87516c2a646572fb27512c03057784f)

10 years agoAdd FreeBSD cert bundle
Ashish SHUKLA [Thu, 24 Dec 2015 17:54:41 +0000 (18:54 +0100)]
Add FreeBSD cert bundle

* doc/misc/emacs-gnutls.texi (Help For Users): Document
FreeBSD bundle.

* lisp/net/gnutls.el (gnutls-trustfiles): Add FreeBSD cert bundle.

Backport:

(cherry picked from commit 60c0f1a18ad88d6dc1a8f4ee5d9d18940eaeb6f7)

10 years agoIgnore invalid SVG images
Lars Ingebrigtsen [Thu, 24 Dec 2015 13:40:16 +0000 (14:40 +0100)]
Ignore invalid SVG images

* shr.el (shr-tag-svg): Ignore SVG images that have no width
or height, because these can't be displayed by ImageMagick,
anyway.

Backport:

(cherry picked from commit 821107d53c2e390240d25c036b99ebbf9b4a93b6)

10 years agoshr table rendering fix
Lars Ingebrigtsen [Thu, 24 Dec 2015 13:00:38 +0000 (14:00 +0100)]
shr table rendering fix

* shr.el (shr-tag-table): Allow rendering body-less tables
that have headers.

Backport:

(cherry picked from commit b05471e42c17e02c56c87d7599ada0c124a5fe09)

10 years agoRestore info about the build host in bug reports
Eli Zaretskii [Fri, 25 Dec 2015 11:35:08 +0000 (13:35 +0200)]
Restore info about the build host in bug reports

* lisp/mail/emacsbug.el (report-emacs-bug): Report the system on
which Emacs was built.  This is important information for
investigating bug reports reported by users who don't build their
Emacs.

10 years agoFix bootstrap broken by changes related to OS X file-name encoding
Eli Zaretskii [Fri, 25 Dec 2015 11:23:17 +0000 (13:23 +0200)]
Fix bootstrap broken by changes related to OS X file-name encoding

* lisp/international/ucs-normalize.el (eval-when-compile): Make
sure char-code-property-alist includes elements that allow access
to 'decomposition' and 'canonical-combining-class' Unicode
properties, as compiling ucs-normalize.el requires that.
* lisp/loadup.el (featurep 'ns): Load ucs-normalize and ns-win
only of charprop.el was already loaded.

* src/Makefile.in ($(lispsource)/international/ucs-normalize.elc):
New order-only dependency.

10 years ago* ido.el (ido-add-virtual-buffers-to-list): Use bookmark-get-filename.
Leo Liu [Fri, 25 Dec 2015 11:10:13 +0000 (19:10 +0800)]
* ido.el (ido-add-virtual-buffers-to-list): Use bookmark-get-filename.

10 years ago; Re-enabled "File-name completion of non-ASCII characters on OS X (bug#22169)""
Anders Lindgren [Fri, 25 Dec 2015 09:55:38 +0000 (10:55 +0100)]
; Re-enabled "File-name completion of non-ASCII characters on OS X (bug#22169)""

; This reverts commit d107eda498f94423d846b0e2f1be7facab417b2a.

; A follow-up to this will be made to ucs-normalize.el etc. to ensure that building from scratch works.

10 years agoMake tramp-test29-vc-registered more robust
Michael Albinus [Fri, 25 Dec 2015 09:45:20 +0000 (10:45 +0100)]
Make tramp-test29-vc-registered more robust

* test/automated/tramp-tests.el (tramp-test29-vc-registered):
Move `bzr' case down.  Skip test when `vc-create-repo' fails.
Remove instrumentation.

10 years ago; Revert "File-name completion of non-ASCII characters on OS X (bug#22169)"
Anders Lindgren [Thu, 24 Dec 2015 08:50:26 +0000 (09:50 +0100)]
; Revert "File-name completion of non-ASCII characters on OS X (bug#22169)"

; This reverts commit 09053075225fec8a6cf7a72017a6dfc1ec6b6f0c.

; This caused a build from scratch to fail.

10 years ago* lisp/term/x-win.el (x-gtk-stock-map): Fix typo.
YAMAMOTO Mitsuharu [Thu, 24 Dec 2015 08:46:01 +0000 (17:46 +0900)]
* lisp/term/x-win.el (x-gtk-stock-map): Fix typo.

10 years agoFix `gnus-union' so as to behave like `cl-union'
Katsumi Yamaoka [Wed, 23 Dec 2015 23:08:55 +0000 (23:08 +0000)]
Fix `gnus-union' so as to behave like `cl-union'

* lisp/gnus/gnus-group.el (gnus-group-prepare-flat):
Make gnus-union use `equal' to compare items in lists.

* lisp/gnus/gnus-util.el (gnus-union):
Make it behave like cl-union partially.

10 years agoFix dired.c typo with ptrdiff_t vs Lisp_Object
Paul Eggert [Wed, 23 Dec 2015 19:47:52 +0000 (11:47 -0800)]
Fix dired.c typo with ptrdiff_t vs Lisp_Object

* src/dired.c (file_name_completion): Don't assume Lisp_Object is
an integer type, fixing a problem introduced in the recent fix for
Bug#22169.

10 years agoDocument default process sentinel more prominently
Eli Zaretskii [Wed, 23 Dec 2015 18:06:28 +0000 (20:06 +0200)]
Document default process sentinel more prominently

* doc/lispref/processes.texi (Asynchronous Processes): Mention the
defaults for process filter and sentinel.  Provide cross-references.
(Process Information): Provide cross-references to where filters
and sentinels are described.
(Filter Functions): Add an index entry for "default filter".
(Sentinels): Add a few status messages not documented previously.
Resolve the "killed" confusion.  Document and describe the default
sentinel.  (Bug#22220)

10 years agoFix file-name completion on OS X
Eli Zaretskii [Wed, 23 Dec 2015 17:34:00 +0000 (19:34 +0200)]
Fix file-name completion on OS X

* src/dired.c (file_name_completion): Reject false matches due to
file-name-coding-systems that decompose characters when encoding
file names, by comparing decoded file names as well.  (Bug#22169)
(syms_of_dired) <Qdecomposed_characters>: New DEFSYM.

* lisp/international/ucs-normalize.el (utf-8-hfs): Give it a
non-nil 'decomposed-characters' property.

10 years agoFile-name completion of non-ASCII characters on OS X (bug#22169)
Anders Lindgren [Wed, 23 Dec 2015 06:15:45 +0000 (07:15 +0100)]
File-name completion of non-ASCII characters on OS X (bug#22169)

The coding system `utf-8-nfd', locally defined in ns-win.el,
didn't provide a :pre-write-conversion method, causing file name
completion of non-ASCII characters to fail.  Solved by using the
`utf-8-hfs' coding system provided by `ucs-normalize'.

* lisp/loadup.el: Load international/ucs-normalize (when building
for ns).

* lisp/term/ns-win.el (utf-8-nfd): Made `utf-8-nfd' as alias for
`utf-8-hfs' and removed the old implementation.  Set `utf-8-hfs'
as the file name coding system.

* src/nsfns.c (ns-convert-utf8-nfd-to-nfc): Removed.

10 years agoFix bug #18588 by making bug-reference-bug-regexp more lenient
Tom Tromey [Wed, 23 Dec 2015 00:02:59 +0000 (17:02 -0700)]
Fix bug #18588 by making bug-reference-bug-regexp more lenient

* lisp/progmodes/bug-reference.el (bug-reference-bug-regexp): Accept
"bug NNNN".  (Bug #18588)

10 years agoadd some cl-* aliases to lisp-mode imenu
Tom Tromey [Tue, 22 Dec 2015 23:53:05 +0000 (16:53 -0700)]
add some cl-* aliases to lisp-mode imenu

* (lisp-imenu-generic-expression): Add cl-define-compiler-macro,
cl-defgeneric, and cl-defmethod.

10 years agoMake a variable buffer-local
Tom Tromey [Sun, 20 Dec 2015 03:11:49 +0000 (20:11 -0700)]
Make a variable buffer-local

* lisp/generic-x.el (generic-rul-mode-setup-function): Make
font-lock-syntax-table buffer-local.  (Bug #21627)

10 years agoFix decoding of text in URLs retrieved by EWW
Eli Zaretskii [Tue, 22 Dec 2015 16:57:51 +0000 (18:57 +0200)]
Fix decoding of text in URLs retrieved by EWW

* lisp/net/eww.el (eww-render): Pass 'charset' to
'eww-display-raw'.  Use the value of 'last-coding-system-used', if
non-nil, to set 'buffer-file-coding-system' of the buffer where we
show the URL.
(eww-display-html, eww-display-raw): Decode the text correctly,
using the charset found in the headers, and defaulting to UTF-8.
If the user told us to use a specific encoding, override the
charset from the headers.  (Bug#22222)

10 years agoFix a coding error in c-forward-<>-arglist-recur. Fixes bug#22156
Alan Mackenzie [Tue, 22 Dec 2015 16:10:35 +0000 (16:10 +0000)]
Fix a coding error in c-forward-<>-arglist-recur.  Fixes bug#22156

* lisp/progmodes/cc-engine.el (c-forward-<>-arglist-recur): Remove unused
variable `tmp'.
After a failed search for a matching ">", restore point before continuing.